package com.sinodata.bsm.common.vo;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

/**
 * EventCauses entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "EVENT_CAUSES")
public class EventCauses implements java.io.Serializable {

    /**
     * 
     */
    private static final long serialVersionUID = -7539304899976827437L;

    // Fields    
    private Long id;
    private Long resId;
    private Long eventTypeId;
    private String title;
    private Long eventId;

    // Constructors

    /** default constructor */
    public EventCauses() {
    }

    /** minimal constructor */
    public EventCauses(Long id) {
        this.id = id;
    }

    /** full constructor */
    public EventCauses(Long id, Long resId, Long eventTypeId, String title, Long eventId) {
        this.id = id;
        this.resId = resId;
        this.eventTypeId = eventTypeId;
        this.title = title;
        this.eventId = eventId;
    }

    // Property accessors
    @Id
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "sequence")
    @SequenceGenerator(name = "sequence", sequenceName = "EVENT_CAUSES_SEQ")
    @Column(name = "ID", unique = true, nullable = false, precision = 22, scale = 0)
    public Long getId() {
        return this.id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Column(name = "RES_ID", precision = 22, scale = 0)
    public Long getResId() {
        return this.resId;
    }

    public void setResId(Long resId) {
        this.resId = resId;
    }

    @Column(name = "EVENT_TYPE_ID", precision = 22, scale = 0)
    public Long getEventTypeId() {
        return this.eventTypeId;
    }

    public void setEventTypeId(Long eventTypeId) {
        this.eventTypeId = eventTypeId;
    }

    @Column(name = "TITLE", length = 50)
    public String getTitle() {
        return this.title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    @Column(name = "EVENT_ID", precision = 22, scale = 0)
    public Long getEventId() {
        return this.eventId;
    }

    public void setEventId(Long eventId) {
        this.eventId = eventId;
    }

    @Override
    public String toString() {
        return "EventCauses [id=" + id + ", resId=" + resId + ", eventTypeId=" + eventTypeId + ", title=" + title + ", eventId=" + eventId + "]";
    }

}